//********************************************************************************************************************//
//ORGANIZATION:
//AUTHOR: bpeng(bogers.peng@gmail.com)
//SUMMARY:
//********************************************************************************************************************//
#ifndef NATIVE_SYSTEM_BASE_SCENE_H
#define NATIVE_SYSTEM_BASE_SCENE_H

#ifndef NATIVE_SYSTEM_BASE_OBJECT_H
#include "System/Base/Object.h"
#endif
#ifndef NATIVE_SYSTEM_BASE_EQUALTO_H
#include "System/Base/EqualTo.h"
#endif

namespace Native { namespace System
{
    //****************************************************************************************************************//
    //CScene
    //It warps location information to indicate specific source code.
    //****************************************************************************************************************//
    NATIVE_DECLARE_CONST_OBJECT(CScene, C_SCENE);
    class NATIVE_LIBRARY_EXPORT CScene :
        public CObject,
        public IEqualTo<CScene>
    {
        NATIVE_DECLARE_OBJECT;
        
        NATIVE_DECLARE_PROPERTY(public, public, wstring, Class, _class);
        NATIVE_DECLARE_PROPERTY(public, public, wstring, Method, _method);
        NATIVE_DECLARE_PROPERTY(public, public, size_t, Line, _line);

    public:
        CScene();
        CScene(C_SCENE& that);
        CScene(C_SCENE&& that);
        CScene(WSTRING& class_name, WSTRING& method, uint32_t line);

    public:
        //Convert to a WSTRING what is like <class name>::<method name>#line number.
        virtual wstring ToString()const;
        //IEqualTo
        virtual bool operator==(C_SCENE& rvalue) const;
        virtual bool operator!=(C_SCENE& rvalue) const;

        C_SCENE& operator=(C_SCENE& rvalue);
    };
}}

#define NATIVE_SCENE(METHOD) \
    CScene(TypeName(), METHOD, __LINE__)

#endif